interface SchemaItemOption<T> {
  type: any;
  unique?: boolean;
  required?: boolean;
  default?: T;
  ref?: string;
}

export interface IndexCondition {
  pageIndex?: number;
  pageSize?: number;
  select?: string | string[];
  populate?: { path?: string; select?: string };
  customSort?: Record<string, any>;
  find?: Record<string, any>;
}

export type SchemaDefinition<T extends Record<string, any>> = {
  [key in keyof T]?: SchemaItemOption<T[key]>;
};
